﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using System.Drawing;


namespace QunYing.Common
{
    [ServiceContract]
    public  interface IImageOperator
    {
      [OperationContract]
      string[] UpLoad(string imageType,string[] imageNames, Bitmap[] images);
      [OperationContract]
      string[] Delete(string imageType,string[] imageNames);
      [OperationContract]
      string[] DeleteImg(string[] imageNames);
      [OperationContract]
      Bitmap[] GetImages(string imageType,string[] imageNames);
      [OperationContract]
      Bitmap[] GetImgs(string[] imageNames);
    }

    [ServiceContract(SessionMode = SessionMode.Required, CallbackContract = typeof(IWarnInfoHandle))]
    public interface IWarnInfoService
    {
        [OperationContract(IsInitiating = true, IsTerminating = false)]
        void RegisterListener(string name,string otherInfo);
        [OperationContract(IsInitiating = false, IsTerminating = false)]
        void UnregisterListener(string name,string otherInfo);
    }

    [ServiceContract] 
    public interface IWarnInfoHandle
    {
        [OperationContract(IsOneWay = true)]
        void ProcessWarnInfo(int warnInfoKey);
    }


    [ServiceContract(SessionMode = SessionMode.Required, CallbackContract = typeof(IOrderInfoHandle))]
    public interface IOrderInfoService
    {
        [OperationContract(IsInitiating = true, IsTerminating = false)]
        void RegisterListener(string name, string otherInfo);
        [OperationContract(IsInitiating = false, IsTerminating = false)]
        void UnregisterListener(string name, string otherInfo);
    }

    [ServiceContract]
    public interface IOrderInfoHandle
    {
        [OperationContract(IsOneWay = true)]
        void ProcessOrderInfo(int orderInfoKey);
    }
}
